package com.kymatrix.kycarbon.xsmd.kbpm.server.core.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.kymatrix.kycarbon.xsmd.kbpm.server.base.CommonPage;
import com.kymatrix.kycarbon.xsmd.kbpm.server.core.dto.ProcessSurrogatePageParam;
import com.kymatrix.kycarbon.xsmd.kbpm.server.core.dto.ProcessSurrogateParam;
import com.kymatrix.kycarbon.xsmd.kbpm.server.model.entity.ProcessSurrogateEntity;
import com.kymatrix.kycarbon.xsmd.kbpm.server.core.vo.ProcessSurrogateEntityVO;
/**
 * <p>
 * 流程委托代理 服务类
 * </p>
 *
 * @author mldong
 * @since 2023-12-06
 */
public interface ProcessSurrogateService extends IService<ProcessSurrogateEntity> {
    /**
    * 添加流程委托代理
    * @param param
    * @return
    */
    boolean save(ProcessSurrogateParam param);

    /**
    * 更新流程委托代理
    * @param param
    * @return
    */
    boolean update(ProcessSurrogateParam param);

    /**
    * 自定义分页查询流程委托代理
    * @param param
    * @return
    */
    CommonPage<ProcessSurrogateEntityVO> page(ProcessSurrogatePageParam param);
    /**
    * 通过id查询
    * @param id
    * @return
    */
    ProcessSurrogateEntityVO findById(Long id);
    /**
     * 获取代理人
     * @param operator
     * @param processName
     * @return
     */
    String getSurrogate(String operator,String processName);
}
